<template>
    <div>
        <div class="search">
            <input type="text" placeholder="请输入要搜索的医院" />
            <span>搜索</span>
        </div>
        <el-table
    :data="tableData"
    border
    style="width: 100%;">
    <el-table-column
      prop="num"
      label="序号"
      align="center"
      width="120">
    </el-table-column>
    <el-table-column
      prop="name"
      label="医院名称"
      align="center"
      width="550">
    </el-table-column>
    <el-table-column
      prop="doctorNum"
      label="医师人数"
      align="center"
      width="220">
    </el-table-column>
    <el-table-column
      prop="quesNum"
      label="问诊次数"
      align="center"
      width="220">
    </el-table-column>
    <el-table-column
      prop="goodNum"
      label="好评度"
      align="center"
      width="200">
    </el-table-column>
      <el-table-column
      fixed="right"
      label="操作"
      align="center"
      width="200">
      <template slot-scope="scope">
        <el-button @click="handleClick(scope.row)" type="text" size="small">进入</el-button>
      </template>
    </el-table-column>
  </el-table>
    </div>
</template>

<script>
export default {
  data () {
    return {
      tableData: [{
        num: '1',
        name: '北京301医院',
        doctorNum: '34355',
        quesNum: '321231',
        goodNum: '99%'
      }, {
        num: '2',
        name: '上海瑞金医院',
        doctorNum: '33555',
        quesNum: '43212',
        goodNum: '98%'
      }, {
        num: '3',
        name: '上海华山医院',
        doctorNum: '2335',
        quesNum: '34432',
        goodNum: '97%'
      }]
    }
  },
  methods: {
    handleClick (row) {
      console.log(row)
      this.$router.push('/hms/offic')
    }
  }
}
</script>

<style scoped>
.search {
    width: 100%;
    height: 40px;
    line-height: 40px;
    text-align: right;
}
input {
    text-align: center;
}
.search>span {
    display: inline-block;
    color: white;
    background: steelblue;
    padding: 5px 15px;
    height: 10px;
    line-height: 10px;
    font-size: 12px;
    margin: 0 10px;
    border-radius: 5px;
}
</style>
